package com.boot.controller;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.boot.entity.Concern;
import com.boot.service.ConcernService;
import com.boot.util.AdResult;

@Controller
public class ConcernController {
	
	@Resource
	private ConcernService concernService;
	
	//添加关注
	@RequestMapping("/concern/concernStore.do")
	@ResponseBody
	public AdResult excuteConcern(Concern concern){
		AdResult result=concernService.concernStoreService(concern);
		return result;
	}
	//是否关注
	@RequestMapping("/concern/isConcern.do")
	@ResponseBody
	public AdResult isConcern(Concern concern){
		AdResult result=concernService.isConsern(concern);
		return result;
	}
	//取消关注
	@RequestMapping("/concern/removeConcern.do")
	@ResponseBody
	public AdResult removeConcern(Concern concern){
		AdResult result=concernService.removeConsern(concern);
		return result;
	}
	
}
